/*  ----------------------------------------------------------------------------
 *  Arello Mobile
 *  Fast 3d Engine
 *  ----------------------------------------------------------------------------
 * Except where otherwise noted, this work is licensed under
 * http://creativecommons.org/licenses/by/3.0
 */
#pragma once

#include <Atom.h>
#include <noise/DataSource.h>
#include <properties/PropertyContainer.h>

namespace liba {
namespace noise {
namespace hard {

class Channel
	: public properties::PropertyContainer
{
public:
	// Attributes for different channel types
	// for any channel
	static const Atom volume_name; 
	static const Atom pitch_name;
	static const Atom loop_name;
	// for 2d-channel
	static const Atom pan_name;
	// for 3d-channel
	static const Atom position_name; 
	static const Atom speed_name;
	static const Atom minimum_distance_name;
	static const Atom maximum_distance_name;

	virtual ~Channel()
	{}
	// for streaming channels: gets ownership over source, which can be 0
	// for static channels: plays loaded sound, deletes source
	virtual void play(DataSource * source)=0;
	virtual void stop()=0;
	virtual bool is_finished()=0;
};

} // namespace hard
} // namespace noise
} // namespace liba
using namespace liba;

